package models

import (
	"time"
)

type User struct {
	UserID       int64     `db:"user_id" json:"userID,string"`
	Username     string    `db:"username" json:"username"`
	Password     string    `db:"password" json:"password"`
	UserNickName string    `db:"user_nick_name" json:"userNickName"`
	CreateTime   time.Time `db:"create_time" json:"createTime"`
	UpdateTime   time.Time `db:"update_time" json:"updateTime"`
	IsDelete     int       `db:"is_delete" json:"isDelete"`
	*Authority   `json:"authority"`
}

type UserAuthority struct {
	UserID      int64 `db:"user_id"`
	AuthorityID int64 `db:"authority_id"`
}

type Authority struct {
	AuthorityID   int64  `db:"authority_id" json:"authorityID,string"`
	AuthorityName string `db:"authority_name" json:"authorityName"`
}
